index.js ➔ ???   B
last analyzed

Complexity

Conditions 5
Paths 16

Size

Total Lines 13

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 5
c 1
b 0
f 0
nc 16
dl 0
loc 13
rs 8.8571
nop 1
1
module.exports = $ => {
2
  const result = []
3
  if ($('head title').length === 0) {
4
    result.push('header that doesn’t have <title> tag')
5
  }
6
  if ($('head meta[name="descriptions"]').length === 0) {
7
    result.push('header that doesn’t have descriptions <meta> tag')
8
  }
9
  if ($('head meta[name="keywords"]').length === 0) {
10
    result.push('header that doesn’t have keywords <meta> tag')
11
  }
12
  return result.length ? result.join('\r\n') : null
13
}
14